package com.better.backend.dataComputingService.model.scoreSelection;

import com.better.common.mongo.model.BaseModel;
import com.better.consist.GlobalTypeEnum;
import lombok.Data;

import java.io.Serializable;

/**
 * Created by Administrator on 2017/11/14.
 * @author tangping
 */
@Data
public class SeleSubujectScoreCalModel extends BaseModel implements Serializable {
    /**
     * 科目id
     */
    private String subjectId;
    /**
     * 科目名称
     */
    private String subjectName;
    /**
     * 成绩
     */
    private Double score;
    /**
     * 班级科目得分排名
     */
    private int classSubjectSortNum;
    /**
     * 年级科目得分排名
     */
    private int schoolSubjectSortNum;
    /**
     * 分数段
     */
    private Integer selectValue;
    /**
     * 分数段name
     */
    private String selectValueName;
    /**
     * 踩线name
     */
    private String footFaultName;
    /**
     * 踩线标准
     */
    private Integer footFault;
    /**
     * 类别(上、下)
     */
    private Integer type;
    /**
     *  踩线类别name
     */
    private String typeName;

    public String getSubjectId() {
        return subjectId;
    }

    public String getSelectValueName() {
        if(this.selectValue !=null)
            return GlobalTypeEnum.getName(this.selectValue);
        return this.selectValueName;
    }

    public String getFootFaultName() {
        if(this.footFault !=null)
            return GlobalTypeEnum.getName(this.footFault);
        return "";
    }
}
